<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"><!-- InstanceBegin template="/Templates/AdminBase.dwt.php" codeOutsideHTMLIsLocked="false" -->
<head>
<title>GI ADMIN</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta http-equiv="expires" content="0">
<meta http-equiv="Pragma" content="no-cache">
<meta http-equiv="Cache-Control" content="no-cache">
<?if(0){?>
<link href="css/admin_all.css" rel="stylesheet" type="text/css" />
<?}?>
<link href="<?=$TPL[url]?>css/admin_all.css" rel="stylesheet" type="text/css" />
<script src="<?=$TPL[url]?>js/admin_all.js" language="javascript"></script>
<script>
var imgpath = '<?=$TPL[url]?>images';
</script>
<!-- InstanceBeginEditable name="head" -->
<style type="text/css">
<!--
.tr31 {
	background:url(<?=$TPL[url]?>images/tr3.gif) left bottom repeat-x;
	font-size:12px;
	line-height:18px;
}
-->
</style>
<!-- InstanceEndEditable -->
</head>
<body>
<div class="tt">
<?if($tabs){?>
  <ul class="nav3">
  <?
  foreach($tabs as $t_name => $t_url ){
  ?>
  <li><a href="<?=$t_url?>"><?=$t_name?></a></li>
  <?}?>
  </ul>
<?}?>
<?if($tip){?>
  <div class="c"></div>
  <h3>功能提示</h3>
  <div class="tr5"><?=$tip?></div>
<?}?>
 <!-- InstanceBeginEditable name="Content" -->
  <form method="post" action="<?=$this->url('Index')?>" onsubmit="return searchFormSubmit(this)" >
    <h2>用户组列表</h2>
  </form>
  <div class="c"></div>
  <form method="post" action="<?=$this->url("Batch")?>"  id="ls_form" onsubmit="return batch_confirm(this);">
    <table width="100%" cellspacing="0" cellpadding="0">
      <tr class="tr3 s3">
        <td width="70"><input type="checkbox" name="checkAll" id="checkAll" onclick="CheckAll(window.ls_form)" /><label for="checkAll">全选</label>        </td>
        <td width="36">ID</td>
        <td nowrap="nowrap"><span class="tal">权限名</span></td>
        <td width="80" class="tal">描述</td>
        <td width="80" class="tal">&nbsp;&nbsp;&nbsp;&nbsp;操 作</td>
      </tr>
      <?foreach($data as $row){?>
      <tr class="tr3" >
        <td><input name="pkv[]" type="checkbox" id="pkv[]" value="<?=$row[$pk]?>" /></td>
        <td><?=$row[$pk]?></td>
        <td nowrap="nowrap"><?=$row['name']?></td>
        <td nowrap="nowrap" class="tal"><?=$row['description']?>        </td>
        <td nowrap="nowrap" class="tal"><a class="fourm-two" href="<?=$this->url('Edit',"$pk={$row[$pk]}")?>"><span class="edit" title="编辑"></span></a><a class="fourm-two" onclick="return del('<?=$row['_userqty']?>')" href="<?=$this->url('Remove',"$pk={$row[$pk]}")?>"><span class="del" title="删除"></span></a></td>
      </tr>
      <?}?>
    </table>
    <div style="padding:10px 10px 10px 0px">
      <table width="100%" border="0" cellpadding="3">
        <tr>
          <td width="69%">将选中项 
            <select name="do" id="do">
              <option value="Remove">删除</option>
            </select>
            &nbsp;&nbsp;&nbsp;<input name="submit" type="submit" value='执 行' /></td>
          <td width="31%"><?=$pager?></td>
        </tr>
      </table>
    </div>
    <div class="c"></div>
    <br/>
  </form>
  <script language="JavaScript" type="text/javascript">
function del(qty){
	if(qty != 0){
		alert("该分组还有"+qty+"位用户。请先将这些用户转移到别的分组，然后再删除该组。");
		return false;
	}
	return confirm('确定要删除此条目吗？');
}
  </script>
  <!-- InstanceEndEditable --></div>
<div class="c"></div>
<div class="bottom">
<?include("Footer")?>
</div>
</body>
<!-- InstanceEnd --></html>
